package com.yb.common.domain;

import java.io.Serializable;
import java.util.List;

import com.yb.common.constant.HttpStatusCode;

import lombok.Data;

@Data
public class PageResult implements Serializable {
	
	private static final long serialVersionUID = 1L;
	
    /** 状态码 */
    private int code;
    /** 消息内容 */
    private String msg;
	/** 总记录数 */
	private int total;
	/** 当前页数据列表 */
	private List<?> rows;
	
	public PageResult() {
		super();
	}
	public PageResult(int total, List<?> rows) {
		super();
		this.code = HttpStatusCode.OK;
		this.msg = "操作成功";
		this.total = total;
		this.rows = rows;
	}
	public PageResult(int code, String msg, int total, List<?> rows) {
		super();
		this.code = code;
		this.msg = msg;
		this.total = total;
		this.rows = rows;
	}
}
